home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d15 / mewin.arc / FORTRAN.RC < prev    next >
Text File  |  1991-03-12  |  2KB  |  79 lines

  1. add-global-mode "wrap"
  2. add-global-mode "magic"
  3. 72 set-fill-column
  4. 6 handle-tab
  5. bind-to-key execute-macro-30 M-S-FN4
  6. bind-to-key execute-macro-36 ^J
  7. bind-to-key execute-macro-35 ^M
  8. bind-to-key execute-macro-39 M-C
  9. ;; insert comment
  10. 39 store-macro
  11.        newline
  12.        insert-string "C     "
  13.     bind-to-key execute-macro-37 ^J
  14.     bind-to-key execute-macro-34 M-S-FN4
  15.     bind-to-key execute-macro-38 ^M
  16. !endm
  17. ;; reset after comment macro
  18. 38 store-macro
  19.     newline
  20.     insert-string "      "
  21.     set-mark
  22.     bind-to-key execute-macro-30 M-S-FN4
  23.     bind-to-key execute-macro-36 ^J
  24.     bind-to-key execute-macro-35 ^M
  25.     bind-to-key execute-macro-33 " "
  26. !endm
  27. ;; macro for comments -- handles ^J
  28. 37 store-macro
  29.     newline
  30.     insert-string "C     "
  31. !endm
  32. ;; macro for regular fortran lines -- handles ^J
  33. 36 store-macro
  34.     newline
  35.     insert-string "     + "
  36. !endm
  37. ;;macro for regular lines -- handles ^M
  38. 35 store-macro
  39.     newline
  40.     insert-string "      "
  41.     set-mark
  42.     bind-to-key execute-macro-33 " "
  43. !endm
  44. ;; indent macro for comments only
  45. 34 store-macro
  46.     wrap-word
  47.     set-mark
  48.     beginning-of-line
  49.     insert-string "C     "
  50.     handle-tab
  51.     exchange-point-and-mark
  52. !endm
  53. ;; handle numbered lines
  54. 33 store-macro
  55.     exchange-point-and-mark
  56.     set %firstid #$cbufname
  57.     backward-character
  58.     !if %firstid
  59.         beginning-of-line
  60.         kill-to-end-of-line
  61.         insert-string %firstid
  62.         handle-tab
  63.     !else
  64.         insert-string " "
  65.     !endif
  66.     unbind-key " "
  67. !endm
  68. ;; indent macro for normal lines
  69. 30 store-macro
  70.     wrap-word
  71.     set-mark
  72.     beginning-of-line
  73.     insert-string "     +  "
  74.     exchange-point-and-mark
  75. !endm
  76.  
  77.  
  78.  
  79.